﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace z.Controllers {
	public class OrderController : Controller {
		//
		// GET: /Order/

		public ActionResult Index() {
			return View();
		}
		public ActionResult Adminster() {
			return View();
		}
		public ActionResult _Adminster(FormCollection fc) {
			using(m.db.Database db=new m.db.Database()){
				int id;
				int.TryParse(fc.Get("ID"),out id);
				var order=db.Orders.Where(x => x.ID == id).Single();
				//order.Address = fc.Get("Address");
                //order.MapLocation = fc.Get("MapLocation");
                db.SaveChanges();
				return View(order);
			}
		}
	}
}
